<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
  </head>
  <body>
    <script>
      const a = 0.1;
      const b = 0.2;
      const c = a + b;
      console.log(+c.toFixed(2) === 0.3);

      console.log("0.1 + 0.2", 0.1 + 0.2);
      console.log("0.1 + 0.2===0.3", 0.1 + 0.2 === 0.3);


      console.log((0.1).toString(2));
      console.log((0.2).toString(2));
      console.log((0.3).toString(2));
    </script>
  </body>
</html>
